The present invention relates to transmission and reception of fibre channel frames by a fibre channel node, and, in particular, to a method and fibre channel interface controller implementation for non-blocking, concurrent transmission of data frames and reception of data frames and acknowledgement frames.
The fibre channel (xe2x80x9cFCxe2x80x9d) is an architecture and protocol for a data communications network for interconnecting computers and peripheral devices. The FC supports a variety of upper-level protocols, including the small computer systems interface (xe2x80x9cSCSIxe2x80x9d) protocol. A computer or peripheral device is linked to the network through an FC port and an FC link comprising copper wires or optical fibres, the computer or peripheral device, FC port, and FC link together referred to as an xe2x80x9cFC node.xe2x80x9d An FC port includes a transceiver and an interface controller, and the computer or peripheral device in which the FC port is contained is called a xe2x80x9chost.xe2x80x9d Hosts generally contain one or more processors, referred to as the xe2x80x9chost processorxe2x80x9d in the current application. The FC port exchanges data with the host via a local data bus, such as a peripheral computer interface (xe2x80x9cPCIxe2x80x9d) bus. The interface controller conducts lower-level protocol exchanges between the fibre channel and the computer or peripheral device in which the FC port resides.
An interface controller within an FC port serves essentially as a transducer between the serial receiver and transmitter components of the FC port and the host processor of the FC node in which the FC port is contained. The interface controller is concerned with, on the input side, assembling serially-encoded data received from the receiver component into ordered sets of bytes, assembling a majority of the ordered sets of bytes into basic units of data exchange, called xe2x80x9cFC frames,xe2x80x9d and passing the FC frames, along with status information, to the host processor within the context of larger collections of FC frames, called FC sequences and FC exchanges. On the output side, the interface controller accepts host memory buffer references and control information from the host processor, transforms them into FC frames, within higher-level contexts of FC sequences and FC exchanges, and provides the FC frames to the transmitter component of the FC port for serial transmission to the FC. The interface controller also exchanges lower-level control messages with remote nodes via the FC that are used for configuring the FC, maintaining state within FC nodes, establishing temporary paths between nodes, arbitrating control of FC loops, acknowledging receipt of FC data frames, and extending data transfer credits to remote nodes, among other things.
The interface controller communicates with the host processor through a set of host memory-based data structures and through a number of control registers accessible to both the interface controller and the host processor via a local bus, such as a PCI bus. At any given instant, the interface controller may be handling outgoing FC frames associated with different FC sequences, and may be also handling inbound FC frames from the FC associated with a number of FC sequences. The interface controller uses internal caches to cache information from the host memory-based data structures with which the interface controller communicates with the host processor.
The interface controller plays an analogous function within an FC port as that played by a computer processor in a multi-tasking operating system environment. The interface controller handles many different events concurrently with extremely dynamic patterns of state changes and information flow. The state of an interface controller is maintained in a number of different dynamic data structures and queues, generally stored within host memory, and accessible to both the interface controller and the host. The state of each currently active FC exchange and FC sequence is maintained in these data structures, as well as descriptors that reference incoming and outgoing frames, completion messages for write and read operations, and other such information.
I/O operations may be conducted within the context of a SCSI I/O operation embedded within the FC protocol. An I/O operation is initiated by an initiator node in order to read data from, or write data to, a target node. At the conclusion of a write or read operation (xe2x80x9cI/O operationxe2x80x9d), the initiator node generally receives a FC response frame from the target node, whether or not the I/O operation successfully completes. This FC response frame is received by the interface controller from the FC, the data contents of the FC response frame are transferred to a buffer in host memory, and a completion notice is placed into a separate completion queue in host memory by the interface controller. Thus, data is sent from the interface controller to two different host memory locations upon reception by the initiating node of a response FC frame.
In FC controllers, as in operating systems and other real-time device controllers, queues are employed for buffering output data and input data. In a typical FC controller, inbound frames are received by the FC interface controller from the transceiver component of the FC node that contains the FC interface controller and placed into an inbound first-in-first-out (xe2x80x9cFIFOxe2x80x9d) queue within the FC interface controller.
FC frames include FC data frames and FC link-control frames. One type of FC link-control frame is an acknowledgement (xe2x80x9cACKxe2x80x9d) frame. An FC node sends ACK frames to remote nodes from which the FC node has received FC data frames in order to acknowledge receipt of the FC data frames. FC nodes employ an end-to-end (xe2x80x9cEExe2x80x9d) credit management strategy in which an FC node must obtain credits prior to transmitting FC frames to a remote node. In addition to acknowledging receipt of an FC frame, ACK frames are used to transfer credits to a remote node to allow the remote node to send additional frames to an FC node. ACK frames are also employed for a number of additional functions that are beyond the scope of the current application.
Because, in typical FC interface controller implementations, a single inbound FIFO queue is used for queuing received FC frames, FC data frames and ACK frames are commonly interleaved within the inbound FIFO queue. FC data frames are generally much larger than ACK frames, and require more extensive processing than ACK frames by both the FC interface controller and host processor within an FC node. Processing of queued ACK frames may be temporarily blocked when the ACK frames are preceded in the inbound FIFO queue by FC data frames. When processing of ACK frames queued to the inbound FIFO queue are temporarily blocked, the FC node fails to obtain credits from remote nodes in a timely fashion, resulting in blocking of transmission of outbound FC frames from the FC node to remote nodes. In certain cases, deadlock conditions may arise when processing of inbound ACK frames by two intercommunicating FC nodes is blocked. Such ACK frame processing blockages may increase the inter-frame gap on the FC link, increase the likelihood of EE credit timeouts, decrease bandwidth availability of the FC link, increase I/O latency, cause additional performance problems, and increase the number of loop arbitrations undertaken by an FC node during I/O transactions. For these reasons, FC interface controller architects, developers, and manufacturers, as well as users of FC-based networking and storage systems, have recognized a need for more optimal, non-blocking processing of FC data frames and ACK frames by FC interface controllers.
The present invention provides a method and FC interface controller implementation that employ separate FIFO queues for link-control frames and FC data frames to prevent FC data frames queued ahead of ACK frames from blocking ACK frame processing. In one embodiment of the present invention, an interface controller includes an inbound FC data frame FIFO queue and an inbound link-control frame queue. Thus, inbound FC data frames are queued separately from inbound ACK frames. Functionality that resides in an inbound data manager component of prior art FC interface controllers is, in FC interface controllers representing one embodiment of the present invention, moved to an outbound sequence manager component and an inbound frame router component, simplifying and streamlining processing of ACK frames. The present invention thus reduces the latency in converting ACK frames into credits, prevents a blockage in processing inbound FC data frames within the FC interface controller from blocking processing of inbound ACK frames and transformation of inbound ACK frames into credits, more completely separates the processing of inbound and outbound frames within the interface controller, and increases the efficiency of outbound frame processing and transmission by the FC interface controller. This, in turn, decreases the inter-frame gap on the FC link associated with the FC interface controller, decreases the likelihood of EE credit timeouts, increases bandwidth availability of the FC link, decreases I/O latency, increases general performance, and decreases the number of loop arbitrations undertaken by an FC node within an FC arbitrated loop topology during I/O transactions.